package com.rabbit.message.Receiver;

import org.springframework.amqp.rabbit.annotation.RabbitHandler;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

/**
 * 消息消费者
 * 监听 hello 队列
 * 处理 hello 队列
 */
@Component
@RabbitListener(queues = "hello")
public class Receicer {
    //处理
    @RabbitHandler
    public void process(String hello){
        System.out.println("Receiver"+hello);
    }
}
